<!DOCTYPE html>
<html>
<head>
    <% include ../common/meta.ejs %>
    <% include ../common/public.ejs %>
</head>
<body>
<% include ../common/header.ejs %>

<div class="container">
    <div class="dolphin-row main page-content">
        <div class="page-header">
            <h5 class="content-title">资产模型</h5>
            <div class="pull-left">
                <ul class="fl">
                    <li>
                        <button class="btn btn-block btn-info add_new"><i class="fui-plus-circle icon-menu"></i>
                            <span>新建根模型</span>
                        </button>
                    </li>
                    <li>
                        <button class="btn btn-block btn-success add_sub"><i class="fui-plus-circle icon-menu"></i>
                            <span>新建子模型</span>
                        </button>
                    </li>
                </ul>
            </div>
        </div>
        <div class="dolphin-col-24">
            <div class="dolphin-row">
                <div class="dolphin-col-8">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            <div class="panel-title">
                                模型树
                            </div>
                        </div>
                        <div class="panel-body">
                            <div id="categoryTree"></div>
                        </div>
                    </div>
                </div>
                <div class="dolphin-col-16" id="infoPanel">
                    <div class="panel panel-primary">
                        <div class="panel-heading">
                            <div class="panel-title">
                                <h3 class="panel-title">
                                    <i aria-hidden="true" class="fa fa-table fa-lg"></i>
                                    模型属性
                                </h3>
                                <div class="operationButton" style="float: right;margin-top:-26px;margin-right: -15px;">
                                    <button id="multipleUpdateAttr" class="btn btn-success btn-sm" type="button">
                                        <span class="glyphicon glyphicon-sort dolphin-rotate-90"></span>
                                        添加/删除属性
                                    </button>
                                </div>
                            </div>
                        </div>
                        <div id="itemList"></div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                <h4 class="modal-title" id="myModalLabel">新增类别</h4>

            </div>
            <div class="modal-body">
                <form id="categoryForm" class="form-horizontal">
                    <input type="hidden" name="parent.id"/>
                    <input type="hidden" name="id"/>
                    <div class="dolphin-row">
                        <div class="dolphin-col-24">
                            <div class="form-group">
                                <label class="dolphin-col-6 control-label">模型编码</label>
                                <div class="dolphin-col-18">
                                    <input type="text" class="form-control" name="code"/>
                                </div>
                            </div>
                        </div>
                        <div class="dolphin-col-24">
                            <div class="form-group">
                                <label class="dolphin-col-6 control-label">模型名称</label>
                                <div class="dolphin-col-18">
                                    <input type="text" class="form-control" name="name"/>
                                </div>
                            </div>
                        </div>
                        <div class="dolphin-col-24">
                            <div class="form-group">
                                <label class="dolphin-col-6 control-label">
                                    模型图标
                                </label>
                                <div class="dolphin-col-18">
                                    <input type="text" class="form-control" name="categoryIcon"/>
                                </div>
                            </div>
                        </div>
                        <div class="dolphin-col-24">
                            <div class="form-group">
                                <label class="dolphin-col-6 control-label">
                                    备注
                                </label>
                                <div class="dolphin-col-18">
                                    <textarea class="form-control" style="height: 100%;" name="remark" cols="2"></textarea>
                                </div>
                            </div>
                        </div>
                    </div>
                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-primary modelSave">确定</button>
                <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
            </div>
        </div>
    </div>
</div>


<div class="modal" id="attr_relation_win">
    <div class="modal-dialog" style="width: 70%;left: 20%;top: 0;">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal"
                        aria-label="Close">
                    <span aria-hidden="true">&times;</span>
                </button>
                <span class="modal-title">模型属性维护</span>
            </div>
            <div class="modal-body">
                <div class="dolphin-row">
                    <div class="dolphin-col-9">
                        <div id="selectedList"></div>
                    </div>
                    <div class="dolphin-col-3" style="margin-top: 50px;">
                        <button class="btn btn-info btn-block selectbtn" change="select" all="true">&lt;&lt;</button>
                        <button class="btn btn-info btn-block selectbtn" change="select">&lt;</button>
                        <br/><br/>
                        <button class="btn btn-success btn-block selectbtn" change="unSelect">&gt;</button>
                        <button class="btn btn-success btn-block selectbtn" change="unSelect" all="true">
                            &gt;&gt;</button>
                    </div>
                    <div class="dolphin-col-12">
                        <div id="unselectedList"></div>
                    </div>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-primary relation_submit">保存</button>
                <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
            </div>
        </div>
        <!-- /.modal-content -->
    </div>
</div>

<% include ../common/footer.ejs %>
</body>
</html>
